package com.itmuch.usercenter.rocketmq;

import lombok.extern.slf4j.Slf4j;
import org.springframework.cloud.stream.annotation.StreamListener;
import org.springframework.cloud.stream.messaging.Sink;
import org.springframework.stereotype.Service;

/**
 * @author caiqian
 * @date 2021/5/10 11:43
 */
@Service
@Slf4j
public class TestStreamConsumer {

  @StreamListener(Sink.INPUT)
  public void Receive(String messageBody) {
    log.info("通过stream收到了消息,messageBody={}", messageBody);
  }

}
